﻿
@{
    Layout = null;
}

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>欢迎使用，请登录</title>
    <!-- Tell the browser to be responsive to screen width -->
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
    <!-- Bootstrap 4.1.0 -->
    <link href="~/components/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
    <!-- Font Awesome -->
    <link rel="stylesheet" href="~/components/font-awesome/css/font-awesome.min.css">
    <!-- Ionicons -->
    <link rel="stylesheet" href="~/components/Ionicons/css/ionicons.min.css">
    <!-- Theme style -->
    <link rel="stylesheet" href="~/css/AdminLTE.min.css">
    <!-- iCheck -->
    <link rel="stylesheet" href="~/lib/iCheck/square/blue.css">

    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
    <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
    <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
    <![endif]-->
</head>
<body class="hold-transition login-page">
    <div class="login-box">
        <div class="login-logo">
            <a href="https://github.com/VictorTzeng/Zxw.Framework.NetCore" target="_blank"><b>Zxw.Framework.NetCore</b></a>
        </div>
        <!-- /.login-logo -->
        <div class="login-box-body">
            <p class="login-box-msg">欢迎使用</p>

            <form action="@Url.Action("SignIn")" method="post" role="form" id="login-form">
                @Html.AntiForgeryToken()
                <div class="form-group has-feedback">
                    <input type="text" class="form-control" placeholder="用户名/电话/邮箱" name="account" required>
                    <span class="fa fa-user-circle form-control-feedback"></span>
                </div>
                <div class="form-group has-feedback">
                    <input type="password" class="form-control" placeholder="密码" name="password" required>
                    <span class="fa fa-lock form-control-feedback"></span>
                </div>
                <div class="row">
                    <!-- /.col -->
                    <div class="col-xs-4 pull-right">
                        <button type="submit" class="btn btn-primary btn-block btn-flat">登录</button>
                    </div>
                    <!-- /.col -->
                </div>
            </form>

            @*<div class="social-auth-links text-center">
                <p>- OR -</p>
                <a href="#">
                    <i class="fa fa-qq fa-2x text-blue"></i>
                </a>
                &nbsp;
                <a href="#">
                    <i class="fa fa-wechat fa-2x text-success"></i>
                </a>
<a href="#">
            <i class="fa fa-weibo fa-2x"></i>
        </a>
        <a href="#">
            <i class="fa fa-twitter fa-2x"></i>
        </a>
        <a href="#">
            <i class="fa fa-facebook fa-2x"></i>
        </a>
        <a href="#">
            <i class="fa fa-2x"></i>
        </a>
        <a href="#">
            <i class="fa fa-whatsapp fa-2x"></i>
        </a>
        </div>*@
        <!-- /.social-auth-links -->

        <a href="#">忘记密码?</a><br>
        </div>
        <!-- /.login-box-body -->
    </div>
    <!-- /.login-box -->
    <!-- jQuery 3 -->
    <script src="~/components/jquery/dist/jquery.min.js"></script>
    <script src="~/lib/layer/layer.js"></script>
    <!-- Bootstrap 3.3.7 -->
    <script src="~/components/bootstrap/dist/js/bootstrap.min.js"></script>
    <!-- jquery.form.js -->
    <script src="https://cdn.bootcss.com/jquery.form/4.2.2/jquery.form.min.js"></script>
    <script type="text/javascript">
        $(function () {
            $("#login-form").ajaxForm({
                //dataType: "json",
                //beforeSubmit: function() {
                //    return true;
                //},
                success: function(rep) {
                    if (rep.success == true) {
                        layer.msg("登录成功",
                            function() {
                                location.href = '@Url.Action("Index","Home")';
                            });
                    } else {
                        layer.alert(rep.msg, { icon: 5 });
                    }
                },
                error: function() {
                    layer.alert("网络开小差啦，请稍候再试", { icon: 5 });
                }
            });
        });
    </script>
</body>
</html>
